home *** CD-ROM | disk | FTP | other *** search
/ Aminet 1 (Walnut Creek) / Aminet - June 1993 [Walnut Creek].iso / aminet / disk / cache / smartdisk131.readme < prev    next >
Text File  |  1992-09-30  |  3KB  |  85 lines

  1. Short: Pre-reading disk cache
  2.  
  3. This is SmartDisk1.3.1, written by David Le Blanc.
  4.  
  5. * removed some accidental 2.0 dependent code.
  6. * added command line parameters
  7.  
  8. It is an '8-Way set associative' cache, with 8 sets, lines of 4 sectors with
  9. prefetch, and 32 lines. If you under stand cache jargon, then you'd know that
  10. adds up to:
  11.  
  12. 32*4*8*512 = 524288 or 512K and sectors are 'prefetched' four at a time.
  13.  
  14. The frefetch strips time of program loading and directories. It may 
  15. work against you on a heavily fragmented disk, but there is a general
  16. noticable gain in performance EVEN when the data you want is not in
  17. the cache.
  18.  
  19. So, this cache uses 512k, which gets allocated as the cache expands.
  20. There are a few limitations, but thats only because all parameters are
  21. hard coded into the source.
  22.  
  23. | Since you cannot specify the type of drive you have, there are three versions
  24. | in the archive.
  25.  
  26. | SmartDisk.xt      : Any xt.device user (A590 xt/ide drive)
  27. | SmartDisk.scsi    : Any scsi.device user, (a590 scsi, A2091 etc)
  28. | SmartDisk.gvpscsi : Any gvpscsi.device user, namely all GVP controllers.
  29. ^ Obsolete.
  30.  
  31. Arguments:
  32.  
  33. SmartDisk <devicename> <unit>
  34.  
  35. ******** ******** ******** ******** ******** ******** ******** ********
  36.  
  37. I Must put a note in here to warn users with multiple drives. THIS
  38. PROGRAM WILL FAIL on a system which uses the same device (eg scsi.device)
  39. for many physical units. The reason is that it patches the device 'BeginIO'
  40. vector, effectively catching calls to read ANY unit, but it does not
  41. internally differentiate amongst different devices. The reason is simple,
  42. there is not indication of the 'unit' in the IOStdReq structure. 
  43.  
  44. (There is a 'Unit' pointer but that is device private and I'd be stupid
  45. to depend on it :-)
  46.  
  47. The effect is that if a read from unit 1 gets cached, the same read to 
  48. unit 0 may grab an entry from the cache which actually came from unit
  49. 1! (can you spell BOOM!!) 
  50.  
  51. BE WARNED!
  52.  
  53. ******** ******** ******** ******** ******** ******** ******** ********
  54.  
  55.  
  56.  * SmartDisk 1.3.1 
  57.  * 
  58.  * Added code to grab device and unit from the command line.
  59.  * Removed 2.0 dependent code which had crept in. (CreateMsgPort() instead of
  60.  * CreatePort() for example)
  61.  *
  62.  * SmartDisk 1.3.
  63.  *
  64.  * Created by David Le Blanc 29/10/91 Absolutely no copywrite. But if you improve
  65.  * it, please send me a new version (with source!) 
  66.  * 
  67.  * Some performance quotes: (Doesn't everyone make these??)
  68.  * Background:  I have a directory called MAN: which has 355 manuals.
  69.  *
  70.  * WARNING: These are bad examples, since a 'dir' reads the disk, then sorts the
  71.  * contents, then writes the data to the screen. These times include the sorting
  72.  * and output of the directory. This sorting and output time is in the order
  73.  * of 1.5 to 2 seconds.
  74.  *
  75.  * Normal DIR MAN:        12 seconds
  76.  * Cache enabled but empty      9  seconds (prefetch does work!) 
  77.  * Cache primed                 5  seconds.
  78.  *
  79.  * With a slower drive and/or faster machine these times can only improve.
  80.  * I have a drive capable of 800k/sec on my unaccelerated A500. Those with
  81.  * a 150K/sec A590 would notice a greater performance boost. Same for those
  82.  * with 'bloody fast machines' (grumble :) If I was REALLY worried about making
  83.  * the statistic look good, then I'd test it on an A590.
  84.  *
  85.